import { ApiProperty } from '@nestjs/swagger';
import { IsNotEmpty } from 'class-validator';

export class CreateCommentDto {
  @IsNotEmpty({ message: '标题必填' })
  @ApiProperty({ description: '用户名', required: true, default: 'aaa' })
  readonly wzid: string;

  @IsNotEmpty({ message: '内容必填' })
  @ApiProperty({ description: '内容', required: true, default: 'ccc' })
  readonly content: string;

  @ApiProperty({
    description: '是否有回复，0 为没有 1是有',
    required: false,
    default: 0,
  })
  readonly type: number;
  @ApiProperty({ description: '是否有回复', required: false, default: null })
  readonly to_uid: number;
}

export class getIdComDto {
  @IsNotEmpty({ message: 'ID必填' })
  @ApiProperty({ description: 'ID', required: true, default: '1' })
  readonly id: string;
}
